all: ./bin/dictProduce ./bin/noDuplicate ./bin/invertIndex ./bin/searcherServer
INCLUDES:=./  ./include
CXXFLAGS:=-o
LIBS:= -lm -llog4cpp -lhiredis -lpthread 
Modle1:= ./bin/dictProduce
Modle21:= ./bin/noDuplicate
Modle22:= ./bin/invertIndex
Modle31:= ./bin/searcherServer

# 目标 : 依赖
$(Modle1): ./bin/dictProduceMain.o ./bin/Mylogger.o ./bin/Configuration.o ./bin/DictProducer.o ./bin/SplitTool.o
	g++ $^ $(CXXFLAGS) $@ $(LIBS) $(addprefix -I, $(INCLUDES)) -g

# 目标 : 依赖
$(Modle21): ./bin/cleanPageMain.o ./bin/tinyxml2.o ./bin/CleanPage.o ./bin/Configuration.o ./bin/Mylogger.o 
	g++ $^ $(CXXFLAGS) $@ $(LIBS) $(addprefix -I, $(INCLUDES)) -g

# 目标 : 依赖
$(Modle22): ./bin/invertIndexMain.o ./bin/InvertedIndex.o ./bin/Configuration.o ./bin/Mylogger.o ./bin/tinyxml2.o ./bin/SplitTool.o 
	g++ $^ $(CXXFLAGS) $@ $(LIBS) $(addprefix -I, $(INCLUDES)) -g

# 目标 : 依赖
$(Modle31): ./bin/TestSearcherServer.o ./bin/LRUCache.o ./bin/KeyRecommander.o ./bin/SplitTool.o ./bin/tinyxml2.o ./bin/Configuration.o ./bin/Dictionary.o ./bin/Mylogger.o ./bin/WebPageQuery.o ./bin/WebPageSearcher.o ./bin/TcpConnection.o ./bin/MyTask.o ./bin/EventLoop.o ./bin/Socket.o ./bin/SocketIO.o ./bin/Acceptor.o ./bin/TaskQueue.o ./bin/InetAddress.o ./bin/SearcherServer.o ./bin/TcpServer.o ./bin/ThreadPool.o
	g++ $^ $(CXXFLAGS) $@ $(LIBS) $(addprefix -I, $(INCLUDES)) -g

./bin/%.o:./src/%.cc
	g++ -c $^ $(CXXFLAGS) $@ $(LIBS) $(addprefix -I, $(INCLUDES)) -g

